package cn.itcast.erp.entity;

import cn.itcast.erp.entity.utils.Base;
import org.springframework.stereotype.Component;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * 部门实体类
 * @author 崔凯铭
 * @date 2019/6/5
 */

@Component
public class Dep extends Base implements Serializable {

	private Long uuid;//编号

	@NotBlank(message = "部门名不能为空")
	private String name;//部门名称


	@Pattern(regexp = "[1-9]{6}",message = "电话号码不符合规则")
	private String tele;//联系电话

	@Override
	public String toString() {
		return "Dep{" +
				"uuid=" + uuid +
				", name='" + name + '\'' +
				", tele='" + tele + '\'' +
				'}';
	}

	public Long getUuid() {
		return uuid;
	}
	public void setUuid(Long uuid) {
		this.uuid = uuid;
	}
	public String getName() {		
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getTele() {		
		return tele;
	}
	public void setTele(String tele) {
		this.tele = tele;
	}

}
